<?php
	header("content-type:text/html;charset=utf-8");
	$username=$_GET['username'];
	$conn=mysqli_connect("localhost:3306","root","root","weidian");
	$sql="select * from user where username='$username'";
	$result=mysqli_query($conn,$sql);
	$row=mysqli_num_rows($result);
	if($row>=1){
		echo "1";
	}else{
		echo "0";
	}
?>